import request from '/@/utils/request';

/**
 * （不建议写成 request.post(xxx)，因为这样 post 时，无法 params 与 data 同时传参）
 *
 * 登录api接口集合
 * @method signIn 用户登录
 * @method signOut 用户退出登录
 */
export function tourtableapi() {
	return {
		//增加
		tourtablesave: (data: object) => {
			return request({
				method: 'post',
				url: '/merchant/tourtable/savetable',
				data,
			});
		},
			//查询
		imgselect: (params?: object) => {
				return request({
					url: '/merchant/image/selectimg',
					method: 'get',
					params:params,
				});
		},
			//查询项目数据
		selectone: (params?: object) => {
				return request({
					url: '/merchant/tourtable/selectone',
					method: 'get',
					params:params,
				});
		},
		//修改
		unpdatetour: (data: object) => {
			return request({
				method: 'post',
				url: '/merchant/tourtable/unpdate',
				data,
			});
		},
			//删除图片
			deleteimg: (params?: object) => {
				return request({
					url: '/merchant/image/deleteimg',
					method: 'delete',
					params: params,
				});
			},

			//增加图片
			addimage: (params?: object) => {
				return request({
					url: '/merchant/image/addimage',
					method: 'post',
					params: params,
				});
			},
			addvoideo: (params?: object) => {
				return request({
					url: '/merchant/image/addvoido',
					method: 'post',
					params: params,
				});
			},
	};
}
